import { Module, ClassSerializerInterceptor } from '@nestjs/common';
import { ConfigModule } from './common/config/config.module';
import { UsersModule } from './modules/users/users.module';
import { DbModule } from './common/db/db.module';
import { AuthModule } from './common/auth/auth.module';
import { ResourcesModule } from './modules/resources/resources.module';
import { APP_INTERCEPTOR } from '@nestjs/core';
import { CaptchaModule } from './common/captcha/captcha.module';

@Module({
  imports: [
    AuthModule,
    ConfigModule,
    DbModule,
    UsersModule,
    ResourcesModule,
    CaptchaModule,
  ],
  controllers: [],
  providers: [
    {
      provide: APP_INTERCEPTOR,
      useClass: ClassSerializerInterceptor,
    },
  ],
})
export class AppModule {}
